﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Markup;
using System.Windows.Controls;
using System.Windows;
using System.Windows.Shapes;
using System.Windows.Media;

namespace Bluebunnie
{
    [ContentProperty("DashboardContent")]
    public class DashboardPanel: UserControl
    {
        Border bd = new Border();
        Grid layoutRoot = new Grid();
        Rectangle rect = new Rectangle();
        TextBlock label = new TextBlock();
        
        public DashboardPanel ()
	    {
            this.Content = layoutRoot;
            layoutRoot.Children.Add(rect);
            layoutRoot.Children.Add(bd);
            layoutRoot.Children.Add(label);
            label.FontSize = 16;
            label.FontStyle = FontStyles.Italic;
            label.Margin = new Thickness(15);
            bd.Margin = new Thickness(5,30,5,5);
            bd.Padding = new Thickness(15);
            rect.RadiusX = 10;
            rect.RadiusY = 10;
            rect.Fill = new SolidColorBrush(Colors.LightGray);
            rect.Margin = new Thickness(8);
	    }

        public UIElement DashboardContent
        {
            get { return bd.Child; }
            set { bd.Child = value; }
        }

        public string Title
        {
            get { return label.Text; }
            set { label.Text = value; }
        }

    }
}
